/*
 * @Author: doing
 * @Date: 2023-08-10 09:36:21
 * @LastEditors: git config user.name && git config user.email
 * @LastEditTime: 2023-08-10 09:39:13
 * @FilePath: \线狮少年\src\composables\auth.js
 * @Description: 
 * 获取token和设置token
 * Copyright (c) 2023 by 1540265624@qq.com, All Rights Reserved. 
 */
import { useCookies } from '@vueuse/integrations/useCookies'
const TokenKey = 'admin-token'
const cookie = useCookies()

//获取token
export function getToken(){
    return cookie.get(TokenKey)
}

//设置token
export function setToken(token){
    return cookie.set(TokenKey,token)
}

//清除token
export function removeToken(){
    return cookie.remove(TokenKey)
}

